Event and command functions

(int)eventType = getInputEvent(int *arg1, int *arg2, int *arg3, int *arg4, int *arg5) This command gets the next user input event and returns a description of it. EventType is the type of event: eventType=1 is a keyboard event. In this case the ASCII character will be returned in arg1 and the IBM PC keyboard scan code will be returned in arg2.

eventType=2 is a mouse event. In this case: arg1 is the mouse event mask, arg2 is the mouse button state, arg3 is the vertical mouse position, arg4 is the horizontal mouse position, and arg5 is 's internal mouse event identifier for this event. The mouse event identifier must be passed back to if you want to handle the mouse event.

handleInputEvent(int eventType, int arg1, int arg2) eventType is the eventType from the ``getInputEvent'' call. If eventType=1, arg1 is the ASCII character and arg2 is the scan code. This call can also be used to feed any keystrokes into and have them acted upon. It is not necessary to have gotten the keyboard event from ``getInputEvent''. If eventType=2, arg1 is the mouse event identifier gotten from ``getInputEvent''.

pointCommand(int commandNumber, unsigned int windowId) commandNumber is the command number (see the reference manual for a list of command numbers) of a command to be executed windowId is the windowId of the window on which you want the command to act